package cn.tedu.order.feign;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;
import result.JsonResult;

@FeignClient("micro-service-stock") //nacos中对应的服务名称
public interface StockClient {
    //调用购物车的新增接口
    @PostMapping("/stock/reduce")
    JsonResult reduceStock(@RequestParam("productCode") String productCode,
                           @RequestParam("count") Integer count);
}
